var t = require("../../../../@babel/runtime/helpers/regeneratorRuntime"), e = require("../../../../@babel/runtime/helpers/asyncToGenerator"), i = require("../../../../common/vendor.js"), r = require("../../../uv-ui-tools/libs/mixin/mpMixin.js"), n = require("../../../uv-ui-tools/libs/mixin/mixin.js");

require("../../../uv-ui-tools/libs/function/index.js"), require("../../../uv-ui-tools/libs/function/test.js"), 
require("../../../uv-ui-tools/libs/function/digit.js"), require("../../../uv-ui-tools/libs/util/route.js"), 
require("../../../uv-ui-tools/libs/function/debounce.js"), require("../../../uv-ui-tools/libs/function/throttle.js");

var o = {
    name: "uv-drop-down",
    mixins: [ r.mpMixin, n.mixin ],
    emits: [ "click" ],
    props: {
        isSticky: {
            type: Boolean,
            default: !0
        },
        sign: {
            type: [ String, Number ],
            default: "UVDROPDOWN"
        },
        defaultValue: {
            type: Array,
            default: function() {
                return [ 0, "0", "all" ];
            }
        },
        textSize: {
            type: String,
            default: "30rpx"
        },
        textColor: {
            type: String,
            default: "#333"
        },
        textActiveSize: {
            type: String,
            default: "30rpx"
        },
        textActiveColor: {
            type: String,
            default: "#3c9cff"
        },
        extraIcon: {
            type: Object,
            default: function() {
                return {
                    name: "arrow-down",
                    size: "30rpx",
                    color: "#333"
                };
            }
        },
        extraActiveIcon: {
            type: Object,
            default: function() {
                return {
                    name: "arrow-up",
                    size: "30rpx",
                    color: "#3c9cff"
                };
            }
        }
    },
    computed: {
        parentData: function() {
            return [ this.defaultValue, this.textSize, this.textColor, this.textActiveColor, this.textActiveSize, this.extraIcon, this.extraActiveIcon, this.sign, this.clickHandler ];
        }
    },
    mounted: function() {
        this.init();
    },
    methods: {
        init: function() {
            var r = this;
            i.index.$emit("".concat(this.sign, "_CLICKMENU"), {
                show: !1
            }), this.$nextTick(e(t().mark(function e() {
                var n;
                return t().wrap(function(t) {
                    for (;;) switch (t.prev = t.next) {
                      case 0:
                        return t.next = 2, r.queryRect();

                      case 2:
                        n = t.sent, i.index.$emit("".concat(r.sign, "_GETRECT"), n);

                      case 4:
                      case "end":
                        return t.stop();
                    }
                }, e);
            })));
        },
        queryRect: function() {
            var t = this;
            return new Promise(function(e) {
                t.$uvGetRect(".uv-drop-down").then(function(t) {
                    e(t);
                });
            });
        },
        clickHandler: function(t) {
            this.$emit("click", t);
        }
    }
};

Array || i.resolveComponent("uv-sticky")(), Math;

var u = i._export_sfc(o, [ [ "render", function(t, e, r, n, o, u) {
    return {
        a: i.s(t.$uv.addStyle(t.customStyle)),
        b: i.p({
            disabled: !r.isSticky
        })
    };
} ], [ "__scopeId", "data-v-64391769" ] ]);

wx.createComponent(u);